home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 26
/
Cream of the Crop 26.iso
/
program
/
sockdem.zip
/
_SETUP.1
/
mswinsockcontrol.cpp
next >
Wrap
C/C++ Source or Header
|
1997-06-17
|
4KB
|
180 lines
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
// NOTE: Do not modify the contents of this file. If this class is regenerated by
// Microsoft Visual C++, your modifications will be overwritten.
#include "stdafx.h"
#include "mswinsockcontrol.h"
/////////////////////////////////////////////////////////////////////////////
// CMSWinsockControl
IMPLEMENT_DYNCREATE(CMSWinsockControl, CWnd)
/////////////////////////////////////////////////////////////////////////////
// CMSWinsockControl properties
/////////////////////////////////////////////////////////////////////////////
// CMSWinsockControl operations
long CMSWinsockControl::GetProtocol()
{
long result;
InvokeHelper(0x3, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
return result;
}
void CMSWinsockControl::SetProtocol(long nNewValue)
{
static BYTE parms[] =
VTS_I4;
InvokeHelper(0x3, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
nNewValue);
}
CString CMSWinsockControl::GetRemoteHostIP()
{
CString result;
InvokeHelper(0x4, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
return result;
}
CString CMSWinsockControl::GetLocalHostName()
{
CString result;
InvokeHelper(0x5, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
return result;
}
CString CMSWinsockControl::GetLocalIP()
{
CString result;
InvokeHelper(0x6, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
return result;
}
long CMSWinsockControl::GetSocketHandle()
{
long result;
InvokeHelper(0x7, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
return result;
}
long CMSWinsockControl::GetRemotePort()
{
long result;
InvokeHelper(0x1, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
return result;
}
void CMSWinsockControl::SetRemotePort(long nNewValue)
{
static BYTE parms[] =
VTS_I4;
InvokeHelper(0x1, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
nNewValue);
}
long CMSWinsockControl::GetLocalPort()
{
long result;
InvokeHelper(0x2, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
return result;
}
void CMSWinsockControl::SetLocalPort(long nNewValue)
{
static BYTE parms[] =
VTS_I4;
InvokeHelper(0x2, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
nNewValue);
}
short CMSWinsockControl::GetState()
{
short result;
InvokeHelper(0x8, DISPATCH_PROPERTYGET, VT_I2, (void*)&result, NULL);
return result;
}
long CMSWinsockControl::GetBytesReceived()
{
long result;
InvokeHelper(0x9, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
return result;
}
void CMSWinsockControl::Connect(const VARIANT& RemoteHost, const VARIANT& RemotePort)
{
static BYTE parms[] =
VTS_VARIANT VTS_VARIANT;
InvokeHelper(0x40, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
&RemoteHost, &RemotePort);
}
void CMSWinsockControl::Listen()
{
InvokeHelper(0x41, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
}
void CMSWinsockControl::Accept(long requestID)
{
static BYTE parms[] =
VTS_I4;
InvokeHelper(0x42, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
requestID);
}
void CMSWinsockControl::SendData(const VARIANT& data)
{
static BYTE parms[] =
VTS_VARIANT;
InvokeHelper(0x43, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
&data);
}
void CMSWinsockControl::GetData(VARIANT* data, const VARIANT& type, const VARIANT& maxLen)
{
static BYTE parms[] =
VTS_PVARIANT VTS_VARIANT VTS_VARIANT;
InvokeHelper(0x44, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
data, &type, &maxLen);
}
void CMSWinsockControl::PeekData(VARIANT* data, const VARIANT& type, const VARIANT& maxLen)
{
static BYTE parms[] =
VTS_PVARIANT VTS_VARIANT VTS_VARIANT;
InvokeHelper(0x45, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
data, &type, &maxLen);
}
void CMSWinsockControl::Close()
{
InvokeHelper(0x46, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
}
void CMSWinsockControl::Bind(const VARIANT& LocalPort, const VARIANT& LocalIP)
{
static BYTE parms[] =
VTS_VARIANT VTS_VARIANT;
InvokeHelper(0x47, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
&LocalPort, &LocalIP);
}
CString CMSWinsockControl::GetRemoteHost()
{
CString result;
InvokeHelper(0xa, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
return result;
}
void CMSWinsockControl::SetRemoteHost(LPCTSTR lpszNewValue)
{
static BYTE parms[] =
VTS_BSTR;
InvokeHelper(0xa, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
lpszNewValue);
}